package com.sloth.bear.dto.entity;

import com.baomidou.mybatisplus.annotation.FieldStrategy;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.sloth.bear.constant.LayoutType;
import com.sloth.bear.dto.base.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;

@Data
@EqualsAndHashCode(callSuper = true)
@TableName("doc")
public class Doc extends BaseEntity {

    private Long namespaceId;

    @TableField(updateStrategy = FieldStrategy.ALWAYS)
    private Long parentId;

    private String name;

    private String content;

    private Boolean isFavorite;

    private LayoutType layoutType;

    private Integer sortNo;

    /**
     * 是否显示目录
     */
    private Boolean isShowToc;

    /**
     * 权限：0 公开 1 私有
     */
    private Integer permission;
}